// 库存管理
import request from '@/utils/request'

// 获取历史库存记录列表
export function getHistoryInventoryList(data) {
  return request({
    url: '/goodsInoutRecord/queryPage',
    method: 'get',
    params: data
  })
}
// 获取库存余量预警列表
export function getWarnRecordList(data) {
  return request({
    url: '/goodsInfo/queryPageBind',
    method: 'get',
    params: data
  })
}
// 根据物料查询绑定货位
export function getGoodsPositionBindApi(data) {
  return request({
    url: '/goodsPositionBind/queryListByGoodsId',
    method: 'get',
    params: data
  })
}
// 导出出入库
export function exportGoodsInoutRecordExcelApi(data) {
  return request({
    url: '/goodsInoutRecord/exportExcel',
    method: 'post',
    responseType: 'blob',
    params: data
  })
}
// 获取货架名称列表
export function getGoodsShelvesInfoList(data) {
  return request({
    url: '/goodsShelvesInfo/queryNameList',
    method: 'get',
    params: data
  })
}
// 获取磅位名称列表
export function getGoodsShelvesPositionList(data) {
  return request({
    url: '/goodsShelvesPosition/queryCodeList',
    method: 'get',
    params: data
  })
}

export function associateTaskApi(data) {
  return request({
    url: '/goodsInoutRecord/associateTaskApi',
    method: 'post',
    data: data
  })
}
